<template>
    <n-list style="background-color:#eeeeee;">
        <!-- {{ props.title }} -->
          <div style="height: 50px;display: flex; align-items: center; justify-content: center;">
            <slot name="header"></slot>
          </div>
        
        <n-list-item v-for="(item,index) in props.data">
           <slot name="pitem" :data="item">

           </slot>
        </n-list-item>
        <div style="">
            <slot name="footer"></slot>
        </div> 
    </n-list>
</template>
<script setup lang="ts">
import {ref,defineProps, watch } from 'vue'

//定义组件
    const props = defineProps({
        data:Array,
        title:String
    }) 

//    watch("props.data",(n,o)=>{
//       console.log(n,o)
//    })
</script>